/***************************************************************************
创建者：华磊
 开始时间：               : 2020.1１.２４
 copyright            : (C) 深圳市华友高科有限公司
 修改说明：（每次有修改就添加一条，带有 修改人，修改时间，修改描述）

 ***************************************************************************
 *   io窗口程序
*                                                                         *
 ***************************************************************************/
#ifndef SYSTEMSTATUS_H
#define SYSTEMSTATUS_H

#include <QWidget>

#include "aistatus.h"
#include "aostatus.h"
#include "sistatus.h"
#include "sostatus.h"
#include "globalregisterstatus.h"
#include "pointregisterstatus.h"
#include "palletregisterstatus.h"
#include "registerstatus.h"
#include "timerstatus.h"
#include "distatus.h"
#include "dostatus.h"
#include "generalstatus.h"
#include <QTranslator>

enum EM_SYS_VIEW_ID{
    EM_SYS_VIEW_DI,
    EM_SYS_VIEW_DO,
    EM_SYS_VIEW_SI,
    EM_SYS_VIEW_SO,
    EM_SYS_VIEW_AI,
    EM_SYS_VIEW_AO,
    EM_SYS_VIEW_GR,
    EM_SYS_VIEW_R,
    EM_SYS_VIEW_PR,
    EM_SYS_VIEW_PL,
    EM_SYS_VIEW_TIME,
    EM_SYS_VIEW_G,
    EM_SYS_VIEW_END
};

namespace Ui{
    class SystemStatus;
}

/**
 * @brief The SystemStatus class　主窗体类
 */
class  SystemStatus : public QWidget
{

    Q_OBJECT

public:

    int nowSysVIewID;

    AiStatus *aiStatusView;
    AoStatus *aoStatusView;
    DiStatus *diStatusView;
    DoStatus *doStatusView;
    GeneralStatus *generalStatusView;
    GlobalRegisterStatus *globalRegisterStatusView;
    PalletRegisterStatus *palletRegisterStatusView;
    PointRegisterStatus *pointRegisterStatusView;
    RegisterStatus *registerStatusView;
    SiStatus *siStatusView;
    SoStatus *soStatusView;
    TimerStatus *timerStatusView;

private:
    QTranslator translator;

public:
    explicit SystemStatus(int styleId,QWidget *parent=0);
    ~SystemStatus();

    /**
     * @brief hideAllStatus　隐藏全部窗体函数
     */
    void hideAllStatus();

    void changeLanguage(int language);
    void initialDisplayStyle(int styleId);

private slots:

    void on_dibutton_clicked();

    void on_dobutton_clicked();

    void on_sibutton_clicked();

    void on_sobutton_clicked();

    void on_aibutton_clicked();

    void on_aobutton_clicked();

    void on_rbutton_clicked();

    void on_prbutton_clicked();

    void on_plbutton_clicked();

    void on_timerbutton_clicked();

    void on_aibutton_2_clicked();

    void on_pushButton_clicked();

private:
    Ui::SystemStatus *ui;

};

#endif // SYSTEMSTATUS_H
